package com.ibm.cloud.banking.prod.entity;

import java.sql.Date;
import java.sql.Timestamp;
import java.util.Objects;

import javax.persistence.Basic;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Id;
import javax.persistence.Table;

/**
 * replace desc in here
 *
 * @author HanDong
 * @date 2022/7/18
 */
@Entity
@Table(name = "product_info")
public class ProductInfoEntity {
    @Basic
    @Column(name = "product_no")
    @Id
    private String productNo;
    @Basic
    @Column(name = "status")
    private String status;
    @Basic
    @Column(name = "name")
    private String name;
    @Basic
    @Column(name = "describe")
    private String describe;
    @Basic
    @Column(name = "start_date")
    private Date startDate;
    @Basic
    @Column(name = "end_date")
    private Date endDate;
    @Basic
    @Column(name = "max_account_count")
    private Integer maxAccountCount;
    @Basic
    @Column(name = "customer_age_range")
    private String customerAgeRange;
    @Basic
    @Column(name = "customer_groups")
    private String customerGroups;
    @Basic
    @Column(name = "create_dt")
    private Timestamp createDt;
    @Basic
    @Column(name = "update_dt")
    private Timestamp updateDt;

    public String getProductNo() {
        return productNo;
    }

    public void setProductNo(String productNo) {
        this.productNo = productNo;
    }

    public String getStatus() {
        return status;
    }

    public void setStatus(String status) {
        this.status = status;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public String getDescribe() {
        return describe;
    }

    public void setDescribe(String describe) {
        this.describe = describe;
    }

    public Date getStartDate() {
        return startDate;
    }

    public void setStartDate(Date startDate) {
        this.startDate = startDate;
    }

    public Date getEndDate() {
        return endDate;
    }

    public void setEndDate(Date endDate) {
        this.endDate = endDate;
    }

    public Integer getMaxAccountCount() {
        return maxAccountCount;
    }

    public void setMaxAccountCount(Integer maxAccountCount) {
        this.maxAccountCount = maxAccountCount;
    }

    public String getCustomerAgeRange() {
        return customerAgeRange;
    }

    public void setCustomerAgeRange(String customerAgeRange) {
        this.customerAgeRange = customerAgeRange;
    }

    public String getCustomerGroups() {
        return customerGroups;
    }

    public void setCustomerGroups(String customerGroups) {
        this.customerGroups = customerGroups;
    }

    public Timestamp getCreateDt() {
        return createDt;
    }

    public void setCreateDt(Timestamp createDt) {
        this.createDt = createDt;
    }

    public Timestamp getUpdateDt() {
        return updateDt;
    }

    public void setUpdateDt(Timestamp updateDt) {
        this.updateDt = updateDt;
    }

    @Override
    public boolean equals(Object o) {
        if (this == o) return true;
        if (o == null || getClass() != o.getClass()) return false;
        ProductInfoEntity that = (ProductInfoEntity) o;
        return Objects.equals(productNo, that.productNo) && Objects.equals(status, that.status) && Objects.equals(name, that.name) && Objects.equals(describe, that.describe) && Objects.equals(startDate, that.startDate) && Objects.equals(endDate, that.endDate) && Objects.equals(maxAccountCount, that.maxAccountCount) && Objects.equals(customerAgeRange, that.customerAgeRange) && Objects.equals(customerGroups, that.customerGroups) && Objects.equals(createDt, that.createDt) && Objects.equals(updateDt, that.updateDt);
    }

    @Override
    public int hashCode() {
        return Objects.hash(productNo, status, name, describe, startDate, endDate, maxAccountCount, customerAgeRange, customerGroups, createDt, updateDt);
    }
}
